package com.graduation.vaccine.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.graduation.vaccine.dto.FamilyDTO;
import com.graduation.vaccine.pojo.VaccinatedInfo;
import com.graduation.vaccine.vo.UpdateVaccinatednVo;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author ZhaoJunYao
 * @since 2022-04-22
 */
@Mapper
public interface VaccinatedInfoMapper extends BaseMapper<VaccinatedInfo> {

    /**
     * 根据手机号查询得到家人列表
     * @return
     */
    List<FamilyDTO> getFamily(String phone);

    /**
     * 添加家人
     * @param familyDTO
     * @return
     */
    Integer addFamily(FamilyDTO familyDTO);

    /**
     * 根据IDCard得到列表
     * @param idCard
     * @return
     */
    List<VaccinatedInfo> getListByIDCard(String idCard);

    /**
     * 修改用户信息
     * @param updateVaccinatednVo
     * @return
     */
    Integer updateVaccinatedInfo(UpdateVaccinatednVo updateVaccinatednVo);
}
